#include "Work.h"

Work::Work()
{
	m_Id = "";
	m_title = "";
}

Work::Work(const Work& work):
       m_Id ( work.m_Id    ),
    m_title ( work.m_title )
{

}

Work& Work::operator = (const Work& work)
{
       m_Id = work.m_Id;
    m_title = work.m_title;
    return *this;
}

Work::Work(const string& title)
{
	m_Id = "";
	m_title = title;
}
	
Work::Work(const string& title, const string& id)
{
	m_Id = id;
	m_title = title;
}

void Work::title(const string& title)
{
	m_title = title;
}

void Work::Id(const string& id)
{
	m_Id = id;
}

string Work::title(void) const
{
	return(m_title);
}
	
string Work::Id(void) const
{
	return(m_Id);
}

void Work::PPrn(Page& p_buff)
{
	string s;
	p_buff.add_line("LAVORO");
	p_buff.add_line("======");
	s.append("Titolo lavoro = ");
	s.append(m_title);
	p_buff.add_line(s);
	s.erase();
	s.append("ID            = ");
	s.append(m_Id);
	p_buff.add_line(s);
	s.erase();
}


